package com.erp.entity.purchase;

import com.fasterxml.jackson.annotation.JsonFormat;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @author :qinya
 * @PackageName:com.erp.entity.purchase
 * @ClassName: PurchaseOrder
 * @Description: 采购单
 * @date : 2025/7/11,10:31
 */
public class PurchaseOrder {

    private Integer purchaseOrderId;// 采购订单id

    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date invoiceDate;// 单据日期

    private String invoiceCode;// 单据编号

    private Integer providerId;// 供应商id

    private Integer salePersonId;// 采购员id

    private String purchaseAmount;// 购货金额

    private Integer discountRate;// 整单折扣率

    private BigDecimal taxAmount;// 税额

    private BigDecimal hasPaid;// 已付款金额

    private Integer orderState;// 订单状态（暂存-提交-审核）

    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date deliveryDate;// 交货日期

    private Integer orderMakerId;// 制单人id

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date orderCreateDate;// 制单时间

    private Integer auditorId;// 审核人

    private String remark;// 备注

    private Integer deliveryMethodId;// 交货方式

    private Integer companyId;// 公司Id

    private List<PurchaseOrderDetail> purchaseOrderDetailList;// 采购订单明细

    private Integer invoiceType;// 单据类型

    private List<String> purchasePreOrderCodeList;// 关联的购货订单编号
    private List<String> purchaseReturnCodeList;// 关联的退货订单编号

    // 冗余字段
    private String providerName;// 供应商名称
    private String providerAddress;// 采购员名称

    public Integer getPurchaseOrderId() {
        return purchaseOrderId;
    }

    public void setPurchaseOrderId(Integer purchaseOrderId) {
        this.purchaseOrderId = purchaseOrderId;
    }

    public Date getInvoiceDate() {
        return invoiceDate;
    }

    public void setInvoiceDate(Date invoiceDate) {
        this.invoiceDate = invoiceDate;
    }

    public String getInvoiceCode() {
        return invoiceCode;
    }

    public void setInvoiceCode(String invoiceCode) {
        this.invoiceCode = invoiceCode;
    }

    public Integer getProviderId() {
        return providerId;
    }

    public void setProviderId(Integer providerId) {
        this.providerId = providerId;
    }

    public Integer getSalePersonId() {
        return salePersonId;
    }

    public void setSalePersonId(Integer salePersonId) {
        this.salePersonId = salePersonId;
    }

    public String getPurchaseAmount() {
        return purchaseAmount;
    }

    public void setPurchaseAmount(String purchaseAmount) {
        this.purchaseAmount = purchaseAmount;
    }

    public Integer getDiscountRate() {
        return discountRate;
    }

    public void setDiscountRate(Integer discountRate) {
        this.discountRate = discountRate;
    }

    public BigDecimal getTaxAmount() {
        return taxAmount;
    }

    public void setTaxAmount(BigDecimal taxAmount) {
        this.taxAmount = taxAmount;
    }

    public BigDecimal getHasPaid() {
        return hasPaid;
    }

    public void setHasPaid(BigDecimal hasPaid) {
        this.hasPaid = hasPaid;
    }

    public Integer getOrderState() {
        return orderState;
    }

    public void setOrderState(Integer orderState) {
        this.orderState = orderState;
    }

    public Date getDeliveryDate() {
        return deliveryDate;
    }

    public void setDeliveryDate(Date deliveryDate) {
        this.deliveryDate = deliveryDate;
    }

    public Integer getOrderMakerId() {
        return orderMakerId;
    }

    public void setOrderMakerId(Integer orderMakerId) {
        this.orderMakerId = orderMakerId;
    }

    public Date getOrderCreateDate() {
        return orderCreateDate;
    }

    public void setOrderCreateDate(Date orderCreateDate) {
        this.orderCreateDate = orderCreateDate;
    }

    public Integer getAuditorId() {
        return auditorId;
    }

    public void setAuditorId(Integer auditorId) {
        this.auditorId = auditorId;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Integer getDeliveryMethodId() {
        return deliveryMethodId;
    }

    public void setDeliveryMethodId(Integer deliveryMethodId) {
        this.deliveryMethodId = deliveryMethodId;
    }

    public Integer getCompanyId() {
        return companyId;
    }

    public void setCompanyId(Integer companyId) {
        this.companyId = companyId;
    }

    public List<PurchaseOrderDetail> getPurchaseOrderDetailList() {
        return purchaseOrderDetailList;
    }

    public void setPurchaseOrderDetailList(List<PurchaseOrderDetail> purchaseOrderDetailList) {
        this.purchaseOrderDetailList = purchaseOrderDetailList;
    }

    public Integer getInvoiceType() {
        return invoiceType;
    }

    public void setInvoiceType(Integer invoiceType) {
        this.invoiceType = invoiceType;
    }

    public String getProviderName() {
        return providerName;
    }

    public void setProviderName(String providerName) {
        this.providerName = providerName;
    }

    public String getProviderAddress() {
        return providerAddress;
    }

    public void setProviderAddress(String providerAddress) {
        this.providerAddress = providerAddress;
    }

    public List<String> getPurchasePreOrderCodeList() {
        return purchasePreOrderCodeList;
    }

    public void setPurchasePreOrderCodeList(List<String> purchasePreOrderCodeList) {
        this.purchasePreOrderCodeList = purchasePreOrderCodeList;
    }

    public List<String> getPurchaseReturnCodeList() {
        return purchaseReturnCodeList;
    }

    public void setPurchaseReturnCodeList(List<String> purchaseReturnCodeList) {
        this.purchaseReturnCodeList = purchaseReturnCodeList;
    }


}
